import request from "@/utils/request";

// 查询Customer列表
export function listCustomer(query) {
  return request({
    url: "/hotelCustomer/list",
    method: "get",
    params: query,
  });
}

// 分页查询Customer列表
export function listCustomerByPage(query) {
  return request({
    url: "/hotelCustomer/page",
    method: "get",
    params: query,
  });
}

// 查询customer
export function getCustomer(id) {
  return request({
    url: "/hotelCustomer/" + id,
    method: "get",
  });
}

// 新增Customer
export function addCustomer(data) {
  return request({
    url: "/hotelCustomer",
    method: "post",
    data: data,
  });
}

// 修改customer
export function updateCustomer(data) {
  return request({
    url: "/hotelCustomer",
    method: "put",
    data: data,
  });
}

// 删除customer
export function deleteCustomer(id) {
  return request({
    url: "/hotelCustomer/delete/" + id,
    method: "delete",
  });
}
